package es.upm.gib.mappingAPI2;

/**
 * This class represents the coordinates of an identifier entity of the model.
 * The first value fo the coordinate represents the path of the class.
 * The second one represents the position of the class into the path
 */
public class Identifier {

    /**
     * Coordinate of the identifier entity.
     */
    private Coordinate coordinate;

    /**
     * Constructor
     * @param path number of the path
     * @param class_ position of the class into the path
     */
    public Identifier(int path, int class_){
        this.coordinate = new Coordinate(path, class_);
    }

    /**
     * This method retrieves the number of path of the identifier class
     * @return path number
     */
    public int getPath(){
        return coordinate.getPath();
    }

    /**
     * This method retrieves the position of the class into the path of the identifier class
     * @return class position
     */
    public int getClass_(){
        return coordinate.getClass_();
    }

    @Override
    public String toString() {
        return coordinate.toString();
    }
}
